<%@ page import="bean.load" %>
<%@ page import="java.util.ArrayList" %>
<%@ page import="bean.record" %>
<%--
  Created by IntelliJ IDEA.
  User: zhujun
  Date: 2023/1/7
  Time: 5:22
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <meta charset="utf-8">
    <title>当前预约挂号</title>
    <link rel="stylesheet" type="text/css" href="../css/table.css">
</head>
<body>
<%@include file="header2.jsp"%>
<%
    load ld = new load();
    String SQL = "select*from reg";
    ArrayList<record> ar = ld.loadrecord(SQL);
    String n1,n2,n3,n4;
%>
<h3>有效预约挂号：</h3>
<table>
    <tr>
        <th>编号</th>
        <th>用户名</th>
        <th>医生编号</th>
        <th>预约挂号时间</th>
    </tr>
    <%
        for(int i=0;i<ar.size();i++){
            n1=ar.get(i).getRec_id();
            n2=ar.get(i).getId();
            n3=ar.get(i).getDoc_id();
            n4=ar.get(i).getRec_time();
    %>
    <tr>
        <td><%=n1%></td>
        <td><%=n2%></td>
        <td><%=n3%></td>
        <td><%=n4%></td>
    </tr>
    <%
        }
    %>
</table>
</body>
</html>
